﻿@using SalePromotion.Extensions
@using SalePromotion.Models
@using SalePromotion.Service
@model SalePromotion.Models.SalePaginationListModel
@{
    ViewBag.Title = "Sale Promotion";
}
@helper SearchFacet(FilterBy by)
    {
        var activeCss = Model.Filter == by ? "active" : string.Empty;
    <li class="@activeCss"><a href="@Url.RouteUrl("Default", new { action = "Index", filter = by })">@by</a></li>
}
<div class="facets">
    <ul class="pills">
        @SearchFacet(FilterBy.All)
        @SearchFacet(FilterBy.Active)
        @SearchFacet(FilterBy.Inactive)
        @SearchFacet(FilterBy.Scheduled)
    </ul>
</div>
@Html.Partial("Search")
<h2>
    Sales</h2>
@Html.Partial("Create")
@Html.Partial("Results")
